﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CourseSystem.Core.Entities;

namespace CourseSystem.Common.Helpers
{
    public class ExamStatusHelper
    {
        public static string GetNameByStatus(int status)
        {
            switch (status)
            {
                case 0:
                    return "正常";
                case 1:
                    return "已交卷";
            }
            return "无状态";
        }

        public static string GetColorByItem(ExamStatusInfo info)
        {
            if (info.Status == 1)
                return "#339933";
            if (info.IsWarning)
                return "#FFCC33";
            return "#FFFFFF";
        }
    }
}
